<!DOCTYPE html>
<html lang="zh_CN">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

</body>
<script type="text/javascript">
    var str1 = 'acdbcdef';

    var findStr = 'cd';

    console.log(str1.lastIndexOf(findStr));
</script>

</html>
